<template>
  <div class="father">
    <h3>父组件</h3>
    <Child
      :a="a"
      :b="b"
      :c="c"
      d="4"
      v-bind="{ x: 100, y: 200, z: 300 }"
      :fn="fnc"
    />
  </div>
</template>

<script setup lang="ts" name="AttrsListeners">
import { ref } from "vue";
import Child from "./Child.vue";
let a = ref(1);
let b = ref(2);
let c = ref(3);
function fnc(val: number) {
  console.log("父组件监听");
  a.value += val;
}
</script>

<style scoped>
.father {
  background-color: rgb(165, 164, 164);
  padding: 20px;
  border-radius: 10px;
}
</style>
